#include<stdio.h>
#include<string.h>

int main()
{
	freopen("data.in","r",stdin);
	freopen("data.out","w",stdout);
	int i=0;
	char a[50][50];
	while (gets(a[i])!=NULL)
		i++;
	if (i<2||i>10)
		printf("Input Error\n");
	else
	{
		int m=1000,j;
		for (j=0;j<i;j++)
			if (m>strlen(a[j]))
				m=strlen(a[j]);
		for (j=0;j<i;j++)
			if (m==strlen(a[j]))
				printf("%s\n",a[j]);
	}
	return 0;
}
